package com.tn.controller.alarm.common.constants;

/**
 * @program: tn_aucy_java
 * @description: 常量类
 * @author: yangjiayao
 * @create: 2021-11-12 09:33
 */
public class Constants {
    public static final Integer DELETE_NO = 0; // deleted字段：未删除
    public static final Integer DELETE_YES = 1; // deleted字段：已删除
    public static final Integer STATUS_UNKNOWN = 0; // status字段：无效/未初始化
    public static final Integer STATUS_VALID = 1; // status字段：有效
    public static final Integer STATUS_EXPIRED = 2; // status字段：过期
    public static final Integer STATUS_LOCKED = 3; // status字段：锁定
    public static final int STATUS_START = 8; // 启动
    public static final int STATUS_PAUSE = 9; // 暂停
    public static final int STATUS_CANCEL = 10; // 撤销
    public static final int STATUS_FINISHED = 99; // 整体完结，完成，结束

    public static final int OPERATE_ADD = 0; // 新增
    public static final int OPERATE_UPDATE = 1; // 修改
    public static final int OPERATE_DELETE = 2; // 删除

    // 生产系统常量
    public static class OtherSys {
        // 生产系统orgId
        public static final String PRODUCE_SYS_ORGID = "HSXG";

        // 生产系统key
        public static final String PRODUCE_SYS_KEY = "55b238ce-37b3-40ca-838c-1707d3f0537a";

        // 响应信息
        public enum STATUS {
            SUCCESS("成功", 1),
            UNKNOWN("未知错误", -1),
            EXPIRE("请求已过期", -2),
            INVALID("消息验证信息不存在或消息被篡改", -3),
            PARAM("参数错误", -4);

            private String message;
            private int code;

            STATUS(String message, int code) {
                this.message = message;
                this.code = code;
            }

            public String getMessage() {
                return message;
            }

            public int getCode() {
                return code;
            }

            public void setMessage(String message) {
                this.message = message;
            }

            public void setCode(int code) {
                this.code = code;
            }
        }
    }

    public static class MQTT {
        /**
         * 告警信息
         */
        public static final String WARNING = "aucy/map/warningTag";

        /**
         * 闸口标签
         */
        public static final String GATE_TAG = "aucy/map/gateTag";

        /**
         * 磅房标签
         */
        public static final String WEIGHT_TAG = "aucy/map/weighTag";
    }

    public static final String WHITELIST_GOODSNAMELOGO_SANHUO_QUKA1 = "SH"; // 散货，取卡标志1
    public static final String WHITELIST_GOODSNAMELOGO_JIANZAHUO = "JZH";
    public static final String WHITELIST_NOTICESYSTEM_CHANGQI_QUKA2 = "场-汽"; // 场-汽，取卡标志2
    public static final String WHITELIST_NOTICESYSTEM_QICHANG = "汽-场";

    public static final String TASKINFO_CUSTOMERCOMPANY_HUANGSHIXIDIAN = "黄石西电"; // 货主单位-黄石西电
    /**
     * 禁止出闸
     */
    public static final int PERMIT_THROUGH_STOP_OUT = 1;
    /**
     * 可以出闸
     */
    public static final int PERMIT_THROUGH_OUT = 0;
    /**
     * 出闸中
     */
    public static final int PERMIT_THROUGH_OUT_ING = 2;
    /**
     * 入闸
     */
    public static final int GATE_IN = 1;
    /**
     * 出闸
     */
    public static final int GATE_OUT = 0;

    /**
     * 重车过磅
     */
    public static final int WEIGHING_OUT = 1;
    /**
     * 空车过磅
     */
    public static final int WEIGHING_IN = 0;

    /**
     * 货车
     */
    public static final String TRUCK = "TRUCK";
    /**
     * 装载车
     */
    public static final String VEHICLE = "VEHICLE";

    /**
     * 进闸字符串
     */
    public static final String IN_STRING = "（进）";

    /**
     * 出闸字符串
     */
    public static final String OUT_STRING = "（出）";

    /**
     * 待绑定
     */
    public static final int BINDING_STATUS_WAIT = 0;
    /**
     * 已绑定
     */
    public static final int BINDING_STATUS_ON = 1;
    /**
     * 已解绑
     */
    public static final int BINDING_STATUS_OFF = 2;

    /**
     * 登录校验结果参数名
     */
    public static final String USER_CHECK_IS_SUPER = "isSuperuser";

    /**
     * code类型的摄像头
     */
    public static final int CODE_TYPE_CAMERA = 1;

    /**
     * ip类型的摄像头
     */
    public static final int IP_TYPE_CAMERA = 2;

    /**
     * 环境参数
     */
    public static final String TEST_ENVIRONMENT = "uat";

    /**
     * 装载车偏移量
     */
    public static final String ALARM_PARAM = "vehicle_deviation";

    /**
     * 告警处理结果
     */
    public static final String ALARM_RESULT = "已处理";

    /**
     * 告警处理状态
     */
    public static final int ALARM_END = 2;

    /**
     * 位置坐标分割符
     */
    public static final String POSITION_DIVISION_SYMBOL = ",";

    /**
     * 定位检测任务检测方向
     */
    public static final String DETECTION_TASK_DIRECTION = "enterleave";
}
